<!doctype html>
<html>
<head>
	<meta charset="utf-8">
	<title>普通全局注册组件</title>
	<script src="vue.js"></script>
</head>
<body>
<div id="app">
  <app-component></app-component>
</div>
<script>
  var appCom = Vue.extend({
      template: '<div>这是组件</div>'
    });
  // 注册
  Vue.component('app-component' , appCom)
  // 创建根实例
  var vm=new Vue({
     el: '#app'
  })
</script>
</body>
</html>
